package com.star.common.schedule;

import com.star.star.service.StarArtEmpowerService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * 定时任务
 *
 * @author yangzj
 */
@Slf4j
@Component
public class ScheduleTask {
    @Autowired
    private StarArtEmpowerService starArtEmpowerService;

    /**
     * 定时授权
     */
    @Scheduled(cron = "1 0 0 * * ?")
    public void scheduleEmpower() {
        starArtEmpowerService.scheduleEmpower();
    }
}
